<titlemenu></titlemenu>
<div class="dj-list">
    <div class="dj-list-body">
        <div party-tree data-selectdzzdm="treeparams.selectdzzdm" data-selectdzzmc="treeparams.selectdzzmc"
             data-defaultselected="treeparams.defaultselected" data-isunfold="treeparams.isunfold"></div>
        <div class="dj-list-content">
            <div class="card">
                <div activate-input activate-select class="header search-header">
                    <div fold-partytree data-isunfold="treeparams.isunfold"></div>
                    <div class="search-param-panel">
                        <div class="search-input">
                            <form class="form-horizontal">
                                <div class="row clearfix form-inline">
                                    <div class="col-lg-2 col-md-2 dj-label">
                                        <label>当前选中组织</label>
                                    </div>
                                    <div class="col-lg-2 col-md-2">
                                        <div class="form-group">
                                            <div class="form-line">
                                                <div class="input-group input-group-search">
                                                    <input name="selectdzzmc" type="text" style="min-width: 90px"
                                                           ng-model="treeparams.selectdzzmc" class="form-control"
                                                           ng-disabled="true"/>
                                                    <span class="input-group-addon"
                                                          ng-click="setisunfold()">选择</span>
                                                </div>
                                            </div>
                                        </div>
                                    </div>
                                    <div class="col-lg-2 col-md-2 dj-label">
                                        <label>资产编号</label>
                                    </div>
                                    <div class="col-lg-2 col-md-2">
                                        <div class="form-group">
                                            <div class="form-line">
                                                <input name="no" class="form-control" type="text"
                                                       ng-keypress="($event.which === 13)?search():0"
                                                       ng-model="selectparams.no"
                                                       placeholder=""/>

                                            </div>
                                        </div>
                                    </div>
                                    <div class="col-lg-2 col-md-2 dj-label">
                                        <label>资产名称</label>
                                    </div>
                                    <div class="col-lg-2 col-md-2">
                                        <div class="form-group">
                                            <div class="form-line">
                                                <input name="name" class="form-control" type="text"
                                                       ng-keypress="($event.which === 13)?search():0"
                                                       ng-model="selectparams.name"
                                                       placeholder=""/>

                                            </div>
                                        </div>
                                    </div>
                                </div>
                                <div class="row clearfix form-inline" ng-show="isShow">
                                    <div class="col-lg-2 col-md-2 dj-label">
                                        <label>保管人</label>
                                    </div>
                                    <div class="col-lg-2 col-md-2">
                                        <div class="form-group">
                                            <div class="form-line">
                                                <input name="userName" class="form-control" type="text"
                                                       ng-keypress="($event.which === 13)?search():0"
                                                       ng-model="selectparams.userName"
                                                       placeholder=""/>

                                            </div>
                                        </div>
                                    </div>
                                    <div class="col-lg-2 col-md-2 dj-label">
                                        <label>状态</label>
                                    </div>
                                    <div class="col-lg-2 col-md-2">
                                        <div class="form-group">
                                            <div class="form-line">
                                                <select class="form-control show-tick" ng-change="search()"
                                                        ng-model="selectparams.state"
                                                        ng-options="type.dickey as type.dicvalue for type in assetStateList"
                                                        class="form-control"
                                                        name="state">
                                                    <option value="">--全部--</option>
                                                </select>

                                            </div>
                                        </div>
                                    </div>
                                </div>
                            </form>
                        </div>
                        <div class="search-btn" style="margin-right: 20px;">
                            <div style="min-width: 13em">
                                <span class="moreSpan" ng-click="isShowClick()"
                                      style='padding-right:1em;cursor:pointer;'>{{moreTxt}}<i class="material-icons"
                                                                                              style="position: relative;top:7px;">{{isShow ? 'expand_less' : 'expand_more'}}</i></span>
                                <button class="btn btn-default1"
                                        ng-click="search()">查询
                                </button>
                                <button class="btn btn-default1 btn-reset"
                                        ng-click="reset()">重置
                                </button>
                            </div>
                        </div>
                    </div>
                    <div class="search-btn" style="margin-right: 20px;">
                        <div style="float: right">
                            <button role-permission-code="assetList.btnAdd" class="btn btn-default1"
                                    ng-click="add()">新增
                            </button>
                            <button role-permission-code="assetList.btnImport" class="btn btn-default1"
                                    ng-click="import()">导入
                            </button>
                            <button role-permission-code="assetList.btnExport" class="btn btn-default1"
                                    ng-click="export()">导出
                            </button>
                        </div>
                    </div>
                </div>
                <div class="body">
                    <div class="zero-list-table-panel">
                        <div class="zero-source-table-div">
                            <table class="table table-bordered table-striped table-hover js-basic-example dataTable text-nowrap">
                                <thead>
                                <tr>
                                    <th>序号</th>
                                    <th>资产编号</th>
                                    <th>资产名称</th>
                                    <th>型号</th>
                                    <th>数量</th>
                                    <th>计量单位</th>
                                    <th>资产原值</th>
                                    <th>税额</th>
                                    <th>价税合计</th>
                                    <th>使用部门</th>
                                    <th>保管单位</th>
                                    <th>保管人</th>
                                    <th>保管时间</th>
                                    <th>当前状态</th>
                                </tr>
                                </thead>
                                <tbody>
                                <tr ng-repeat="it in dataList">
                                    <td scope="row" class="text-center">
                                        {{selectparams.pagesize*(selectparams.pageindex-1)+$index+1}}
                                    </td>
                                    <td>{{it.NO}}</td>
                                    <td>{{it.NAME}}</td>
                                    <td>{{it.MODEL}}</td>
                                    <td>{{it.COUNT}}</td>
                                    <td>{{it.UNITTYPE}}</td>
                                    <td>{{it.ORIGINALVALUE}}</td>
                                    <td>{{it.TAX}}</td>
                                    <td>{{it.PRICETAXTOTAL}}</td>
                                    <td>{{it.USEDZZMC}}</td>
                                    <td>{{it.DZZMC}}</td>
                                    <td>{{it.XM}}</td>
                                    <td>{{it.STARTDATE | date:'yyyy-MM-dd'}}至{{it.ENDDATE | date:'yyyy-MM-dd'}}</td>
                                    <td>{{it.AssetStateName}}</td>
                                </tr>
                                <tr ng-if="dataList.length<=0">
                                    <td colspan="15" style="text-align:center">暂无数据</td>
                                </tr>
                                </tbody>
                            </table>
                        </div>
                        <div class="zero-target-table-div">
                            <table class="table table-bordered table-striped table-hover js-basic-example dataTable text-nowrap">
                                <thead>
                                <tr>
                                    <th>操作</th>
                                </tr>
                                </thead>
                                <tbody>
                                <tr ng-repeat="it in dataList" zero-table-height>
                                    <td>
                                        <button class="btn td-btn bg-light-green waves-effect"
                                                ng-click="edit(it.ASSETID)"
                                                title="编辑">
                                            编辑
                                        </button>
                                        <button class="btn td-btn bg-light-green waves-effect"
                                                ng-click="show(it.ASSETID)"
                                                title="详情">
                                            详情
                                        </button>
                                        <button class="btn td-btn bg-pink waves-effect"
                                                ng-click="updateUser(it.ASSETID)" title="变更保管人">
                                            变更保管人
                                        </button>
                                        <button ng-if="!it.isProcess" class="btn td-btn bg-pink waves-effect"
                                                ng-click="delete(it.ASSETID)" title="删除">
                                            删除
                                        </button>
                                    </td>
                                </tr>
                                <tr ng-if="pageInfo.ptotal==0">
                                    <td colspan="1" style="text-align:center">无</td>
                                </tr>
                                </tbody>
                            </table>
                        </div>
                    </div>
                    <pagination data-pageindex="selectparams.pageindex" data-pagesize="selectparams.pagesize"
                                data-ptotal="pageInfo.ptotal"></pagination>
                </div>
            </div>
        </div>
    </div>
</div>